﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using OgilvyOne.UKNow.IDAL;
using OgilvyOne.UKNow.DAL;
using OgilvyOne.UKNow.Globalization;


namespace OgilvyOne.UKNow.DALFactory
{
    public class NewsPhoneImageDALFactory
    {
        public static readonly IDALNewsPhoneImage ChineseNewsPhoneImageDAL = new NewsPhoneImageDAL(LanguageType.cn);
        public static readonly IDALNewsPhoneImage EnglishNewsPhoneImageDAL = new NewsPhoneImageDAL(LanguageType.en);
        public static IDALNewsPhoneImage Create(int langID)
        {
            if (((LanguageType)Enum.Parse(typeof(LanguageType), langID.ToString())) == LanguageType.cn)
                return ChineseNewsPhoneImageDAL;
            else
                return EnglishNewsPhoneImageDAL;
        }
    }
}
